#include <stdio.h>

void init_reverse(int arr[], int length)
{
    int i;
    int temp;
    for (i = 0; (2 * i - 1) <= length; i++)
    {
        if (2 * i - 1 == length)
            continue;
        temp = arr[i];
        arr[i] = arr[length - 1 - i];
        arr[length - 1 - i] = temp;
    }

    printf("\n");
    int j;
    for (j = 0; j < length; j++)
    {
        printf("%d \n", arr[j]);
    }
}

void avoid_pointer_out(int arr[])
{
    int i;
    for (i = 0; i <= 3; i++)
    {
    }
}

int main()
{
    int arr[] = {1, 2, 3, 4, 5, 6};
    int arr1[] = {1, 2, 3, 4, 5, 6, 7};

    int arrLength = sizeof(arr) / sizeof(arr[0]);
    int arrLength1 = sizeof(arr1) / sizeof(arr1[0]);

    init_reverse(arr, arrLength);
    init_reverse(arr1, arrLength1);
}